package com.ruoyi.system.service.impl;

import java.util.List;
import com.ruoyi.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.system.mapper.HospitalSubscribeRefundRecordMapper;
import com.ruoyi.system.domain.HospitalSubscribeRefundRecord;
import com.ruoyi.system.service.IHospitalSubscribeRefundRecordService;

/**
 * 订单退款记录Service业务层处理
 * 
 * @author ruoyi
 * @date 2025-04-30
 */
@Service
public class HospitalSubscribeRefundRecordServiceImpl implements IHospitalSubscribeRefundRecordService 
{
    @Autowired
    private HospitalSubscribeRefundRecordMapper hospitalSubscribeRefundRecordMapper;

    /**
     * 查询订单退款记录
     * 
     * @param id 订单退款记录主键
     * @return 订单退款记录
     */
    @Override
    public HospitalSubscribeRefundRecord selectHospitalSubscribeRefundRecordById(Long id)
    {
        return hospitalSubscribeRefundRecordMapper.selectHospitalSubscribeRefundRecordById(id);
    }

    /**
     * 查询订单退款记录列表
     * 
     * @param hospitalSubscribeRefundRecord 订单退款记录
     * @return 订单退款记录
     */
    @Override
    public List<HospitalSubscribeRefundRecord> selectHospitalSubscribeRefundRecordList(HospitalSubscribeRefundRecord hospitalSubscribeRefundRecord)
    {
        return hospitalSubscribeRefundRecordMapper.selectHospitalSubscribeRefundRecordList(hospitalSubscribeRefundRecord);
    }

    /**
     * 新增订单退款记录
     * 
     * @param hospitalSubscribeRefundRecord 订单退款记录
     * @return 结果
     */
    @Override
    public int insertHospitalSubscribeRefundRecord(HospitalSubscribeRefundRecord hospitalSubscribeRefundRecord)
    {
        hospitalSubscribeRefundRecord.setCreateTime(DateUtils.getNowDate());
        return hospitalSubscribeRefundRecordMapper.insertHospitalSubscribeRefundRecord(hospitalSubscribeRefundRecord);
    }

    /**
     * 修改订单退款记录
     * 
     * @param hospitalSubscribeRefundRecord 订单退款记录
     * @return 结果
     */
    @Override
    public int updateHospitalSubscribeRefundRecord(HospitalSubscribeRefundRecord hospitalSubscribeRefundRecord)
    {
        return hospitalSubscribeRefundRecordMapper.updateHospitalSubscribeRefundRecord(hospitalSubscribeRefundRecord);
    }

    /**
     * 批量删除订单退款记录
     * 
     * @param ids 需要删除的订单退款记录主键
     * @return 结果
     */
    @Override
    public int deleteHospitalSubscribeRefundRecordByIds(Long[] ids)
    {
        return hospitalSubscribeRefundRecordMapper.deleteHospitalSubscribeRefundRecordByIds(ids);
    }

    /**
     * 删除订单退款记录信息
     * 
     * @param id 订单退款记录主键
     * @return 结果
     */
    @Override
    public int deleteHospitalSubscribeRefundRecordById(Long id)
    {
        return hospitalSubscribeRefundRecordMapper.deleteHospitalSubscribeRefundRecordById(id);
    }
}
